/*
 * @Author
 * @Date: 2021-07-23 09:38:49
 * @LastEditTime: 2022-02-16 10:35:07
 * @Description: 不同环境下对应地址
 */
interface BaseURL {
    development: string
    // test: string
    // production: string
}

// 对应的请求地址
const baseURL: BaseURL = {
    development: '/api',
    // development: 'http://192.168.110.11:8071',
    // development: 'http://192.168.110.12:8071',
    // development: 'http://159.75.214.246/api',
    // development: 'http://159.75.214.246/api',
    // 线上
    // development: 'http://121.201.110.163/api',
    // development: 'http://8.134.129.157:8071',  
    // test: 'http://192.168.110.12:8071',
    // production: 'http://192.168.110.11:8071',
    // production: 'http://192.168.110.12:8071',
    // production: 'http://159.75.214.246/api',

    // 线上
    // production: 'http://121.201.110.163/api',
    // production: 'http://8.134.129.157:8071'
}

/**
 * 根据环境变量获取域名
 */
export function getBaseURL() {
    return baseURL.development
    // return baseURL[process.env.NODE_ENV as keyof BaseURL] || baseURL.production
}
